
//    \brief      set GPIO alternate function
//    \param[in]  alt_func_num: GPIO pin af function
//      \arg        GPIO_AF_0: SYSTEM
//      \arg        GPIO_AF_1: TIMER0, TIMER1
//      \arg        GPIO_AF_2: TIMER2, TIMER3, TIMER4
//      \arg        GPIO_AF_3: TIMER7, TIMER8, TIMER9, TIMER10
//      \arg        GPIO_AF_4: I2C0, I2C1, I2C2
//      \arg        GPIO_AF_5: SPI0, SPI1, SPI2, SPI3, SPI4, SPI5
//      \arg        GPIO_AF_6: SPI2, SPI3, SPI4
//      \arg        GPIO_AF_7: USART0, USART1, USART2, SPI1, SPI2
//      \arg        GPIO_AF_8: UART3, UART4, USART5, UART6, UART7
//      \arg        GPIO_AF_9: CAN0, CAN1, TLI, TIMER11, TIMER12, TIMER13, I2C1, I2C2, CTC
//      \arg        GPIO_AF_10: USB_FS, USB_HS
//      \arg        GPIO_AF_11: ENET
//      \arg        GPIO_AF_12: EXMC, SDIO, USB_HS
//      \arg        GPIO_AF_13: DCI
//      \arg        GPIO_AF_14: TLI
//      \arg        GPIO_AF_15: EVENTOUT

//-------------------------------------------------------------------------
//GPIO Functions
//-------------------------------------------------------------------------
#if GPIO_ENABLE
	t_gpio_def _tbl_bspGpio[] = {
		GPIO_T_INT,   	GPIO_P2,	8,		GPIO_M_OUT_PP,		GPIO_INIT_NULL,	 	//RS485_DE_EN
		GPIO_T_INT,   	GPIO_P3,	7,		GPIO_M_OUT_PP,		GPIO_INIT_NULL,	 	//LED2
	};
	tbl_gpio_def tbl_bspGpio[] = {_tbl_bspGpio, ARR_ENDADR(_tbl_bspGpio)};
#endif

//-------------------------------------------------------------------------
//Serial Parallel Interface Functions
//-------------------------------------------------------------------------


//-------------------------------------------------------------------------
//External Parallel Interface Functions
//-------------------------------------------------------------------------


//-------------------------------------------------------------------------
//I2C Interface Functions
//-------------------------------------------------------------------------

//-------------------------------------------------------------------------
//SPI Interface Functions
//-------------------------------------------------------------------------
#if SPI_ENABLE
	t_spi_def tbl_bspSpiDef[BSP_SPI_QTY] = {
		1,	DEV_PIN_PP,	1,	1,	GPIO_P1,	13,	GPIO_P1,	15,	GPIO_P1,	14,	GPIO_P1,	12,
	};
#endif


//-------------------------------------------------------------------------
//UART Interface Functions
//-------------------------------------------------------------------------
#if UART_ENABLE
	t_uart_def tbl_bspUartDef[BSP_UART_QTY] = {
		UART_T_INT,		0,	GPIO_P0,	9,	UART_MODE_POLL,	GPIO_P0, 10,	DEV_PIN_PP, NULL,	NULL,	7,	//
		UART_T_INT,		1,	GPIO_P0,	2,	UART_MODE_POLL,	GPIO_P0, 3,		DEV_PIN_PP, NULL,	NULL,	7,	//
		UART_T_INT,		2,	GPIO_P1,	10,	UART_MODE_POLL,	GPIO_P1, 11,	DEV_PIN_PP, NULL,	NULL,	7,	//
		UART_T_INT,		3,	GPIO_P0,	0,	UART_MODE_POLL,	GPIO_P0, 1,		DEV_PIN_PP, NULL,	NULL,	8,	//
	};
#endif


//-------------------------------------------------------------------------
//File System Functions
//-------------------------------------------------------------------------




//-------------------------------------------------------------------------
//In Application Programming Functions
//-------------------------------------------------------------------------


